<template>
	<slot></slot>
</template>

<script lang="ts">
	import {
		provide,
		defineComponent,
		reactive,
		watch
	} from 'vue';
	import { configProviderInjectionKey } from './type';
	
	const name = 'kui-config-provider';
	
	import ConfigProviderProps from './props';
	
	export default defineComponent({
		name,
		props: ConfigProviderProps,
		setup(props, { slots }) {
			const config = reactive({
				mode: props.mode,
				color: props.color,
				fontSize: props.fontSize
			});
			
			provide(configProviderInjectionKey, config);
		}
	});
</script>

<style>

</style>